{
OstreeDeployment *deployment = self->deployments->pdata[i];
+ /* Ignore deployments not for this osname */
+ if (strcmp (ostree_deployment_get_osname (deployment), osname) != 0)
+ continue;
+
/* Is this deployment booted? If so, note we're past the booted */
if (self->booted_deployment != NULL &&
ostree_deployment_equal (deployment, self->booted_deployment))
continue;
}
- /* Ignore deployments not for this osname */
- if (strcmp (ostree_deployment_get_osname (deployment), osname) != 0)
- continue;
-
if (!found_booted && !ret_pending)
ret_pending = g_object_ref (deployment);
else if (found_booted && !ret_rollback)